package nl.rivm.screenit.service;

/*-
 * ========================LICENSE_START=================================
 * screenit-base
 * %%
 * Copyright (C) 2012 - 2020 Facilitaire Samenwerking Bevolkingsonderzoek
 * %%
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 * 
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 * =========================LICENSE_END==================================
 */

public interface MailService
{

	boolean sendEmail(String to, String subject, String message);

	boolean sendEmail(String[] to, String subject, String message);

	boolean sendEmail(String to, String subject, String message, MailPriority priority);

	boolean sendEmail(String[] to, String subject, String message, MailPriority priority);

	void sendAsyncMail(AsyncMailer asyncMailer);

	public enum MailPriority
	{

		LOWEST(5),

		LOW(4),

		NORMAL(3),

		HIGH(2),

		HIGHEST(1);

		private final int priority;

		private MailPriority(int priority)
		{
			this.priority = priority;
		}

		public int getPriority()
		{
			return priority;
		}
	}
}
